/* eslint-disable @typescript-eslint/no-explicit-any */
import React from "react";
import "./index.less";
import { ConfigProvider, DatePicker, Modal } from "antd";
import locale from "antd/locale/zh_CN";
import dayjs  from "dayjs";
import "dayjs/locale/zh-cn";
import { IBookingSiteForm } from "./type";
dayjs.locale("zh-cn");
const BookingSiteForm: React.FC<IBookingSiteForm> = ({
  isOpen,
  onConfirm,
  onCancel,
  onChange,
}) => {
  const { RangePicker } = DatePicker;

  return (
    <ConfigProvider locale={locale}>
      <Modal
        title={"预约时间"}
        open={isOpen}
        onOk={onConfirm}
        onCancel={onCancel}
      >
        <RangePicker showTime onChange={onChange} />
      </Modal>
    </ConfigProvider>
  );
};
export default BookingSiteForm;
